Optimal. Leaf size=164 \[ \frac {2 c \text {ArcTan}\left (\frac {\sqrt {a} \tan (e+f x)}{\sqrt {a+a \sec (e+f x)}}\right )}{a^{5/2} f}-\frac {(43 c-3 d) \text {ArcTan}\left (\frac {\sqrt {a} \tan (e+f x)}{\sqrt {2} \sqrt {a+a \sec (e+f x)}}\right )}{16 \sqrt {2} a^{5/2} f}-\frac {(c-d) \tan (e+f x)}{4 f (a+a \sec (e+f x))^{5/2}}-\frac {(11 c-3 d) \tan (e+f x)}{16 a f (a+a \sec (e+f x))^{3/2}} \]
[Out]
________________________________________________________________________________________
Rubi [A]
time = 0.18, antiderivative size = 164, normalized size of antiderivative = 1.00, number of steps
used = 7, number of rules used = 5, integrand size = 25, \(\frac {\text {number of rules}}{\text {integrand size}}\) = 0.200, Rules used = {4007, 4005,
3859, 209, 3880} \begin {gather*} -\frac {(43 c-3 d) \text {ArcTan}\left (\frac {\sqrt {a} \tan (e+f x)}{\sqrt {2} \sqrt {a \sec (e+f x)+a}}\right )}{16 \sqrt {2} a^{5/2} f}+\frac {2 c \text {ArcTan}\left (\frac {\sqrt {a} \tan (e+f x)}{\sqrt {a \sec (e+f x)+a}}\right )}{a^{5/2} f}-\frac {(11 c-3 d) \tan (e+f x)}{16 a f (a \sec (e+f x)+a)^{3/2}}-\frac {(c-d) \tan (e+f x)}{4 f (a \sec (e+f x)+a)^{5/2}} \end {gather*}
Antiderivative was successfully verified.
[In]
[Out]
Rule 209
Rule 3859
Rule 3880
Rule 4005
Rule 4007
Rubi steps
\begin {align*} \int \frac {c+d \sec (e+f x)}{(a+a \sec (e+f x))^{5/2}} \, dx &=-\frac {(c-d) \tan (e+f x)}{4 f (a+a \sec (e+f x))^{5/2}}-\frac {\int \frac {-4 a c+\frac {3}{2} a (c-d) \sec (e+f x)}{(a+a \sec (e+f x))^{3/2}} \, dx}{4 a^2}\\ &=-\frac {(c-d) \tan (e+f x)}{4 f (a+a \sec (e+f x))^{5/2}}-\frac {(11 c-3 d) \tan (e+f x)}{16 a f (a+a \sec (e+f x))^{3/2}}+\frac {\int \frac {8 a^2 c-\frac {1}{4} a^2 (11 c-3 d) \sec (e+f x)}{\sqrt {a+a \sec (e+f x)}} \, dx}{8 a^4}\\ &=-\frac {(c-d) \tan (e+f x)}{4 f (a+a \sec (e+f x))^{5/2}}-\frac {(11 c-3 d) \tan (e+f x)}{16 a f (a+a \sec (e+f x))^{3/2}}+\frac {c \int \sqrt {a+a \sec (e+f x)} \, dx}{a^3}-\frac {(43 c-3 d) \int \frac {\sec (e+f x)}{\sqrt {a+a \sec (e+f x)}} \, dx}{32 a^2}\\ &=-\frac {(c-d) \tan (e+f x)}{4 f (a+a \sec (e+f x))^{5/2}}-\frac {(11 c-3 d) \tan (e+f x)}{16 a f (a+a \sec (e+f x))^{3/2}}-\frac {(2 c) \text {Subst}\left (\int \frac {1}{a+x^2} \, dx,x,-\frac {a \tan (e+f x)}{\sqrt {a+a \sec (e+f x)}}\right )}{a^2 f}+\frac {(43 c-3 d) \text {Subst}\left (\int \frac {1}{2 a+x^2} \, dx,x,-\frac {a \tan (e+f x)}{\sqrt {a+a \sec (e+f x)}}\right )}{16 a^2 f}\\ &=\frac {2 c \tan ^{-1}\left (\frac {\sqrt {a} \tan (e+f x)}{\sqrt {a+a \sec (e+f x)}}\right )}{a^{5/2} f}-\frac {(43 c-3 d) \tan ^{-1}\left (\frac {\sqrt {a} \tan (e+f x)}{\sqrt {2} \sqrt {a+a \sec (e+f x)}}\right )}{16 \sqrt {2} a^{5/2} f}-\frac {(c-d) \tan (e+f x)}{4 f (a+a \sec (e+f x))^{5/2}}-\frac {(11 c-3 d) \tan (e+f x)}{16 a f (a+a \sec (e+f x))^{3/2}}\\ \end {align*}
________________________________________________________________________________________
Mathematica [C] Result contains higher order function than in optimal. Order 4 vs. order 3 in
optimal.
time = 27.00, size = 11243, normalized size = 68.55 \begin {gather*} \text {Result too large to show} \end {gather*}
Warning: Unable to verify antiderivative.
[In]
[Out]
________________________________________________________________________________________
Maple [B] Leaf count of result is larger than twice the leaf count of optimal. \(823\) vs.
\(2(139)=278\).
time = 1.62, size = 824, normalized size = 5.02
method | result | size |
default | \(\frac {\sqrt {\frac {a \left (\cos \left (f x +e \right )+1\right )}{\cos \left (f x +e \right )}}\, \left (-32 \left (\cos ^{2}\left (f x +e \right )\right ) \arctanh \left (\frac {\sqrt {-\frac {2 \cos \left (f x +e \right )}{\cos \left (f x +e \right )+1}}\, \sin \left (f x +e \right ) \sqrt {2}}{2 \cos \left (f x +e \right )}\right ) \sqrt {2}\, \sqrt {-\frac {2 \cos \left (f x +e \right )}{\cos \left (f x +e \right )+1}}\, \sin \left (f x +e \right ) c -43 \left (\cos ^{2}\left (f x +e \right )\right ) \ln \left (-\frac {-\sin \left (f x +e \right ) \sqrt {-\frac {2 \cos \left (f x +e \right )}{\cos \left (f x +e \right )+1}}+\cos \left (f x +e \right )-1}{\sin \left (f x +e \right )}\right ) \sqrt {-\frac {2 \cos \left (f x +e \right )}{\cos \left (f x +e \right )+1}}\, \sin \left (f x +e \right ) c +3 \left (\cos ^{2}\left (f x +e \right )\right ) \ln \left (-\frac {-\sin \left (f x +e \right ) \sqrt {-\frac {2 \cos \left (f x +e \right )}{\cos \left (f x +e \right )+1}}+\cos \left (f x +e \right )-1}{\sin \left (f x +e \right )}\right ) \sqrt {-\frac {2 \cos \left (f x +e \right )}{\cos \left (f x +e \right )+1}}\, \sin \left (f x +e \right ) d -64 \arctanh \left (\frac {\sqrt {-\frac {2 \cos \left (f x +e \right )}{\cos \left (f x +e \right )+1}}\, \sin \left (f x +e \right ) \sqrt {2}}{2 \cos \left (f x +e \right )}\right ) \sqrt {2}\, \sqrt {-\frac {2 \cos \left (f x +e \right )}{\cos \left (f x +e \right )+1}}\, \sin \left (f x +e \right ) c \cos \left (f x +e \right )-86 \ln \left (-\frac {-\sin \left (f x +e \right ) \sqrt {-\frac {2 \cos \left (f x +e \right )}{\cos \left (f x +e \right )+1}}+\cos \left (f x +e \right )-1}{\sin \left (f x +e \right )}\right ) \sqrt {-\frac {2 \cos \left (f x +e \right )}{\cos \left (f x +e \right )+1}}\, \sin \left (f x +e \right ) c \cos \left (f x +e \right )+6 \ln \left (-\frac {-\sin \left (f x +e \right ) \sqrt {-\frac {2 \cos \left (f x +e \right )}{\cos \left (f x +e \right )+1}}+\cos \left (f x +e \right )-1}{\sin \left (f x +e \right )}\right ) \sqrt {-\frac {2 \cos \left (f x +e \right )}{\cos \left (f x +e \right )+1}}\, \sin \left (f x +e \right ) d \cos \left (f x +e \right )-32 \sqrt {-\frac {2 \cos \left (f x +e \right )}{\cos \left (f x +e \right )+1}}\, \sqrt {2}\, \arctanh \left (\frac {\sqrt {-\frac {2 \cos \left (f x +e \right )}{\cos \left (f x +e \right )+1}}\, \sin \left (f x +e \right ) \sqrt {2}}{2 \cos \left (f x +e \right )}\right ) c \sin \left (f x +e \right )+30 \left (\cos ^{3}\left (f x +e \right )\right ) c -14 \left (\cos ^{3}\left (f x +e \right )\right ) d -43 \ln \left (-\frac {-\sin \left (f x +e \right ) \sqrt {-\frac {2 \cos \left (f x +e \right )}{\cos \left (f x +e \right )+1}}+\cos \left (f x +e \right )-1}{\sin \left (f x +e \right )}\right ) \sqrt {-\frac {2 \cos \left (f x +e \right )}{\cos \left (f x +e \right )+1}}\, \sin \left (f x +e \right ) c +3 \ln \left (-\frac {-\sin \left (f x +e \right ) \sqrt {-\frac {2 \cos \left (f x +e \right )}{\cos \left (f x +e \right )+1}}+\cos \left (f x +e \right )-1}{\sin \left (f x +e \right )}\right ) \sqrt {-\frac {2 \cos \left (f x +e \right )}{\cos \left (f x +e \right )+1}}\, \sin \left (f x +e \right ) d -8 \left (\cos ^{2}\left (f x +e \right )\right ) c +8 \left (\cos ^{2}\left (f x +e \right )\right ) d -22 c \cos \left (f x +e \right )+6 d \cos \left (f x +e \right )\right )}{32 f \left (\cos \left (f x +e \right )+1\right )^{2} \sin \left (f x +e \right ) a^{3}}\) | \(824\) |
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Maxima [F]
time = 0.00, size = 0, normalized size = 0.00 \begin {gather*} \text {Failed to integrate} \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Fricas [B] Leaf count of result is larger than twice the leaf count of optimal. 314 vs.
\(2 (147) = 294\).
time = 8.98, size = 721, normalized size = 4.40 \begin {gather*} \left [\frac {\sqrt {2} {\left ({\left (43 \, c - 3 \, d\right )} \cos \left (f x + e\right )^{3} + 3 \, {\left (43 \, c - 3 \, d\right )} \cos \left (f x + e\right )^{2} + 3 \, {\left (43 \, c - 3 \, d\right )} \cos \left (f x + e\right ) + 43 \, c - 3 \, d\right )} \sqrt {-a} \log \left (\frac {2 \, \sqrt {2} \sqrt {-a} \sqrt {\frac {a \cos \left (f x + e\right ) + a}{\cos \left (f x + e\right )}} \cos \left (f x + e\right ) \sin \left (f x + e\right ) + 3 \, a \cos \left (f x + e\right )^{2} + 2 \, a \cos \left (f x + e\right ) - a}{\cos \left (f x + e\right )^{2} + 2 \, \cos \left (f x + e\right ) + 1}\right ) - 64 \, {\left (c \cos \left (f x + e\right )^{3} + 3 \, c \cos \left (f x + e\right )^{2} + 3 \, c \cos \left (f x + e\right ) + c\right )} \sqrt {-a} \log \left (\frac {2 \, a \cos \left (f x + e\right )^{2} + 2 \, \sqrt {-a} \sqrt {\frac {a \cos \left (f x + e\right ) + a}{\cos \left (f x + e\right )}} \cos \left (f x + e\right ) \sin \left (f x + e\right ) + a \cos \left (f x + e\right ) - a}{\cos \left (f x + e\right ) + 1}\right ) - 4 \, {\left ({\left (15 \, c - 7 \, d\right )} \cos \left (f x + e\right )^{2} + {\left (11 \, c - 3 \, d\right )} \cos \left (f x + e\right )\right )} \sqrt {\frac {a \cos \left (f x + e\right ) + a}{\cos \left (f x + e\right )}} \sin \left (f x + e\right )}{64 \, {\left (a^{3} f \cos \left (f x + e\right )^{3} + 3 \, a^{3} f \cos \left (f x + e\right )^{2} + 3 \, a^{3} f \cos \left (f x + e\right ) + a^{3} f\right )}}, \frac {\sqrt {2} {\left ({\left (43 \, c - 3 \, d\right )} \cos \left (f x + e\right )^{3} + 3 \, {\left (43 \, c - 3 \, d\right )} \cos \left (f x + e\right )^{2} + 3 \, {\left (43 \, c - 3 \, d\right )} \cos \left (f x + e\right ) + 43 \, c - 3 \, d\right )} \sqrt {a} \arctan \left (\frac {\sqrt {2} \sqrt {\frac {a \cos \left (f x + e\right ) + a}{\cos \left (f x + e\right )}} \cos \left (f x + e\right )}{\sqrt {a} \sin \left (f x + e\right )}\right ) - 64 \, {\left (c \cos \left (f x + e\right )^{3} + 3 \, c \cos \left (f x + e\right )^{2} + 3 \, c \cos \left (f x + e\right ) + c\right )} \sqrt {a} \arctan \left (\frac {\sqrt {\frac {a \cos \left (f x + e\right ) + a}{\cos \left (f x + e\right )}} \cos \left (f x + e\right )}{\sqrt {a} \sin \left (f x + e\right )}\right ) - 2 \, {\left ({\left (15 \, c - 7 \, d\right )} \cos \left (f x + e\right )^{2} + {\left (11 \, c - 3 \, d\right )} \cos \left (f x + e\right )\right )} \sqrt {\frac {a \cos \left (f x + e\right ) + a}{\cos \left (f x + e\right )}} \sin \left (f x + e\right )}{32 \, {\left (a^{3} f \cos \left (f x + e\right )^{3} + 3 \, a^{3} f \cos \left (f x + e\right )^{2} + 3 \, a^{3} f \cos \left (f x + e\right ) + a^{3} f\right )}}\right ] \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Sympy [F]
time = 0.00, size = 0, normalized size = 0.00 \begin {gather*} \int \frac {c + d \sec {\left (e + f x \right )}}{\left (a \left (\sec {\left (e + f x \right )} + 1\right )\right )^{\frac {5}{2}}}\, dx \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Giac [F(-2)]
time = 0.00, size = 0, normalized size = 0.00 \begin {gather*} \text {Exception raised: TypeError} \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Mupad [F]
time = 0.00, size = -1, normalized size = -0.01 \begin {gather*} \int \frac {c+\frac {d}{\cos \left (e+f\,x\right )}}{{\left (a+\frac {a}{\cos \left (e+f\,x\right )}\right )}^{5/2}} \,d x \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________